home *** CD-ROM | disk | FTP | other *** search
Text File | 1991-10-10 | 1.5 KB | 57 lines | [TEXT/MPS ] |
- {
- Note: I didn't have a chance to test this file before I had to deliver it.
- Let me know how it works if you try it.
- --Dave Johnson
- }
-
- unit FuturesIntf;
-
- uses AppleEvents, Threads;
-
- interface
-
- const
-
- kFuturesNotInitedErr = -2707;
-
-
- type
-
- FuturesProc = ProcPtr;
-
- FuturesProcTbl = record
- fThreadBlock: FuturesProc;
- fThreadUnblock: FuturesProc;
- end;
-
-
-
- { ----------------------------------------------------------- }
-
- { Futures Routines }
-
- function ThreadBlock(var message: AppleEvent): OSErr;
- function ThreadUnblock(var message: AppleEvent): OSErr;
- function InitFutures: OSErr;
- function BlockUntilReal(var message: AppleEvent): OSErr;
- function IsFuture(var message: AppleEvent): boolean;
- function Ask(var question, answer: AppleEvent): OSErr;
- function DisposeFuture(var future: AppleEvent): OSErr;
- function GetFutureSemaphore(var future: AppleEvent): SemaphoreHandle;
-
- { ----------------------------------------------------------- }
-
- implementation
-
- { Futures Routines }
-
- function ThreadBlock(var message: AppleEvent): OSErr; external;
- function ThreadUnblock(var message: AppleEvent): OSErr; external;
- function InitFutures: OSErr; external;
- function BlockUntilReal(var message: AppleEvent): OSErr; external;
- function IsFuture(var message: AppleEvent): boolean; external;
- function Ask(var question, answer: AppleEvent): OSErr; external;
- function DisposeFuture(var future: AppleEvent): OSErr; external;
- function GetFutureSemaphore(var future: AppleEvent): SemaphoreHandle; external;
-
- end.